package cn.micro.eye.entity;

import cn.micro.eye.commons.entity.MicroEntity;
import cn.micro.eye.type.RegisterTypeEnum;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.ToString;

/**
 * <p>
 * 账号表，Account-Member为1-1
 * </p>
 *
 * @author lry
 * @since 2018-10-07
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@ToString(callSuper = true)
@EqualsAndHashCode(callSuper = true)
@TableName("account")
public class Account extends MicroEntity<Account> {

    private static final long serialVersionUID = 1L;
    public static final String MEMBER_ID_FIELD = "member_id";

    /**
     * 当前账号绑定的用户ID
     */
    private Long memberId;
    /**
     * OpenID
     */
    private String openId;
    /**
     * 注册IP
     */
    private String registerIp;
    /**
     * 注册类型
     * {@link RegisterTypeEnum}
     */
    private Integer registerType;

}
